#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include <QMainWindow>
#include <stdio.h>
#include <vector>
#include <QMessageBox>
#include <QTableWidgetItem>

#include <iostream>
#include <string>
#include <fstream>
#include <algorithm>
#include "dlwindow.h"
#include "serverinfo.h"
#include "../MySocket.h"
#include "../SocketException.h"
#include "connexion.h"
#include "../file.h"
#include "dirent.h"
#include <QInputDialog>
#include <QCryptographicHash>
#include "descwindow.h"



using namespace std;
namespace Ui {
class MainWindow;
}

class MainWindow : public QMainWindow
{
    Q_OBJECT
    
public:
    explicit MainWindow(QWidget *parent = 0);

    ~MainWindow();
    
private slots:
    void on_actionServeur_triggered();

    void on_searchButton_clicked();

    void on_connectButton_clicked();

    void on_ListButton_clicked();

    void on_downloadButton_clicked();

    void on_actionDossier_triggered();



    void on_descButton_clicked();

    void on_upButton_clicked();

    void on_searchButton2_clicked();

private:
    Ui::MainWindow *ui;
    void fillGrid (vector<FileDescServ>);
    QMessageBox message;
    string IP,PORT,dlPORT,username,password,directory;
    Connexion *conex;

};

#endif // MAINWINDOW_H
